<!DOCTYPE html>
<html lang="en">
  <head>
    <title>EsFaceIDDbManager Class Reference</title>
    <link rel="stylesheet" type="text/css" href="../css/jazzy.css" />
    <link rel="stylesheet" type="text/css" href="../css/highlight.css" />
    <meta charset='utf-8'>
    <script src="../js/jquery.min.js" defer></script>
    <script src="../js/jazzy.js" defer></script>
    
    <script src="../js/lunr.min.js" defer></script>
    <script src="../js/typeahead.jquery.js" defer></script>
    <script src="../js/jazzy.search.js" defer></script>
  </head>
  <body>
    <a name="//apple_ref/objc/Class/EsFaceIDDbManager" class="dashAnchor"></a>
    <a title="EsFaceIDDbManager Class Reference"></a>
    <header>
      <div class="content-wrapper">
        <p><a href="../index.html">esfaceid 1.1.0 Docs</a> (91% documented)</p>
        <p class="header-right">
          <form role="search" action="../search.json">
            <input type="text" placeholder="Search documentation" data-typeahead>
          </form>
        </p>
      </div>
    </header>
    <div class="content-wrapper">
      <p id="breadcrumbs">
        <a href="../index.html">esfaceid Reference</a>
        <img id="carat" src="../img/carat.png" />
        EsFaceIDDbManager Class Reference
      </p>
    </div>
    <div class="content-wrapper">
      <nav class="sidebar">
        <ul class="nav-groups">
          <li class="nav-group-name">
            <a href="../Classes.html">Classes</a>
            <ul class="nav-group-tasks">
              <li class="nav-group-task">
                <a href="../Classes/EsFaceIDConfig.html">EsFaceIDConfig</a>
              </li>
              <li class="nav-group-task">
                <a href="../Classes/EsFaceIDDbManager.html">EsFaceIDDbManager</a>
              </li>
              <li class="nav-group-task">
                <a href="../Classes/EsFaceIDManager.html">EsFaceIDManager</a>
              </li>
              <li class="nav-group-task">
                <a href="../Classes/EsFaceIDResult.html">EsFaceIDResult</a>
              </li>
              <li class="nav-group-task">
                <a href="../Classes/EsFeature.html">EsFeature</a>
              </li>
            </ul>
          </li>
          <li class="nav-group-name">
            <a href="../Enums.html">Enumerations</a>
            <ul class="nav-group-tasks">
              <li class="nav-group-task">
                <a href="../Enums/EsFaceIDErrorCode.html">EsFaceIDErrorCode</a>
              </li>
              <li class="nav-group-task">
                <a href="../Enums/EsFaceIDProvider.html">EsFaceIDProvider</a>
              </li>
            </ul>
          </li>
        </ul>
      </nav>
      <article class="main-content">
        <section>
          <section class="section">
            <h1>EsFaceIDDbManager</h1>
              <div class="declaration">
                <div class="language">
                  
                  <pre class="highlight objective_c"><code><span class="k">@interface</span> <span class="nc">EsFaceIDDbManager</span> <span class="p">:</span> <span class="nc">NSObject</span></code></pre>

                </div>
              </div>
            <p>人脸数据库管理类</p>

          </section>
          <section class="section task-group-section">
            <div class="task-group">
              <ul>
                <li class="item">
                  <div>
                    <code>
                    <a name="/c:objc(cs)EsFaceIDDbManager(py)databasePath"></a>
                    <a name="//apple_ref/objc/Property/databasePath" class="dashAnchor"></a>
                    <a class="token" href="#/c:objc(cs)EsFaceIDDbManager(py)databasePath">databasePath</a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>数据库地址</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Objective-C</p>
                          <pre class="highlight objective_c"><code><span class="k">@property</span> <span class="p">(</span><span class="n">nonatomic</span><span class="p">,</span> <span class="n">copy</span><span class="p">)</span> <span class="n">NSString</span> <span class="o">*</span><span class="n">databasePath</span><span class="p">;</span></code></pre>

                        </div>
                      </div>
                    </section>
                  </div>
                </li>
                <li class="item">
                  <div>
                    <code>
                    <a name="/c:objc(cs)EsFaceIDDbManager(cm)getSharedInstance"></a>
                    <a name="//apple_ref/objc/Method/+getSharedInstance" class="dashAnchor"></a>
                    <a class="token" href="#/c:objc(cs)EsFaceIDDbManager(cm)getSharedInstance">+getSharedInstance</a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>获取实例</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Objective-C</p>
                          <pre class="highlight objective_c"><code><span class="k">+</span> <span class="p">(</span><span class="n">EsFaceIDDbManager</span> <span class="o">*</span><span class="p">)</span><span class="n">getSharedInstance</span><span class="p">;</span></code></pre>

                        </div>
                      </div>
                    </section>
                  </div>
                </li>
                <li class="item">
                  <div>
                    <code>
                    <a name="/c:objc(cs)EsFaceIDDbManager(im)createDB"></a>
                    <a name="//apple_ref/objc/Method/-createDB" class="dashAnchor"></a>
                    <a class="token" href="#/c:objc(cs)EsFaceIDDbManager(im)createDB">-createDB</a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>创建数据库</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Objective-C</p>
                          <pre class="highlight objective_c"><code><span class="k">-</span> <span class="p">(</span><span class="n">BOOL</span><span class="p">)</span><span class="n">createDB</span><span class="p">;</span></code></pre>

                        </div>
                      </div>
                      <div>
                        <h4>Return Value</h4>
                        <p>YES: 成功，NO：失败</p>
                      </div>
                    </section>
                  </div>
                </li>
                <li class="item">
                  <div>
                    <code>
                    <a name="/c:objc(cs)EsFaceIDDbManager(im)getFeatureByDbName:"></a>
                    <a name="//apple_ref/objc/Method/-getFeatureByDbName:" class="dashAnchor"></a>
                    <a class="token" href="#/c:objc(cs)EsFaceIDDbManager(im)getFeatureByDbName:">-getFeatureByDbName:<wbr></a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>根据dbName获取所有人脸数据</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Objective-C</p>
                          <pre class="highlight objective_c"><code><span class="k">-</span> <span class="p">(</span><span class="n">NSArray</span><span class="o">&lt;</span><span class="n"><a href="../Classes/EsFeature.html">EsFeature</a></span> <span class="o">*&gt;</span> <span class="o">*</span><span class="p">)</span><span class="nf">getFeatureByDbName</span><span class="p">:(</span><span class="n">NSString</span> <span class="o">*</span><span class="p">)</span><span class="nv">dbName</span><span class="p">;</span></code></pre>

                        </div>
                      </div>
                      <div>
                        <h4>Parameters</h4>
                        <table class="graybox">
                          <tbody>
                            <tr>
                              <td>
                                <code>
                                <em>dbName</em>
                                </code>
                              </td>
                              <td>
                                <div>
                                  <p>数据库名称</p>
                                </div>
                              </td>
                            </tr>
                          </tbody>
                        </table>
                      </div>
                      <div>
                        <h4>Return Value</h4>
                        <p>数据库中特征数据列表</p>
                      </div>
                    </section>
                  </div>
                </li>
                <li class="item">
                  <div>
                    <code>
                    <a name="/c:objc(cs)EsFaceIDDbManager(im)findByDbName:persionID:"></a>
                    <a name="//apple_ref/objc/Method/-findByDbName:persionID:" class="dashAnchor"></a>
                    <a class="token" href="#/c:objc(cs)EsFaceIDDbManager(im)findByDbName:persionID:">-findByDbName:<wbr>persionID:<wbr></a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>根据dbName和用户id获取这个用户的数据</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Objective-C</p>
                          <pre class="highlight objective_c"><code><span class="k">-</span> <span class="p">(</span><span class="n">NSArray</span><span class="o">&lt;</span><span class="n"><a href="../Classes/EsFeature.html">EsFeature</a></span> <span class="o">*&gt;</span> <span class="o">*</span><span class="p">)</span><span class="nf">findByDbName</span><span class="p">:(</span><span class="n">NSString</span> <span class="o">*</span><span class="p">)</span><span class="nv">dbName</span>
                             <span class="nf">persionID</span><span class="p">:(</span><span class="n">NSString</span> <span class="o">*</span><span class="p">)</span><span class="nv">persionID</span><span class="p">;</span></code></pre>

                        </div>
                      </div>
                      <div>
                        <h4>Parameters</h4>
                        <table class="graybox">
                          <tbody>
                            <tr>
                              <td>
                                <code>
                                <em>dbName</em>
                                </code>
                              </td>
                              <td>
                                <div>
                                  <p>数据库名称</p>
                                </div>
                              </td>
                            </tr>
                            <tr>
                              <td>
                                <code>
                                <em>persionID</em>
                                </code>
                              </td>
                              <td>
                                <div>
                                  <p>离线人脸实人ID</p>
                                </div>
                              </td>
                            </tr>
                          </tbody>
                        </table>
                      </div>
                      <div>
                        <h4>Return Value</h4>
                        <p>特征数据</p>
                      </div>
                    </section>
                  </div>
                </li>
                <li class="item">
                  <div>
                    <code>
                    <a name="/c:objc(cs)EsFaceIDDbManager(im)insertFeature:"></a>
                    <a name="//apple_ref/objc/Method/-insertFeature:" class="dashAnchor"></a>
                    <a class="token" href="#/c:objc(cs)EsFaceIDDbManager(im)insertFeature:">-insertFeature:<wbr></a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>插入人脸特征数据</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Objective-C</p>
                          <pre class="highlight objective_c"><code><span class="k">-</span> <span class="p">(</span><span class="n">BOOL</span><span class="p">)</span><span class="nf">insertFeature</span><span class="p">:(</span><span class="n"><a href="../Classes/EsFeature.html">EsFeature</a></span> <span class="o">*</span><span class="p">)</span><span class="nv">feature</span><span class="p">;</span></code></pre>

                        </div>
                      </div>
                      <div>
                        <h4>Parameters</h4>
                        <table class="graybox">
                          <tbody>
                            <tr>
                              <td>
                                <code>
                                <em>feature</em>
                                </code>
                              </td>
                              <td>
                                <div>
                                  <p>人脸特征数据</p>
                                </div>
                              </td>
                            </tr>
                          </tbody>
                        </table>
                      </div>
                      <div>
                        <h4>Return Value</h4>
                        <p>YES: 执行成功，NO：执行失败</p>
                      </div>
                    </section>
                  </div>
                </li>
                <li class="item">
                  <div>
                    <code>
                    <a name="/c:objc(cs)EsFaceIDDbManager(im)deleteFeature:"></a>
                    <a name="//apple_ref/objc/Method/-deleteFeature:" class="dashAnchor"></a>
                    <a class="token" href="#/c:objc(cs)EsFaceIDDbManager(im)deleteFeature:">-deleteFeature:<wbr></a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>删除人脸数据</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Objective-C</p>
                          <pre class="highlight objective_c"><code><span class="k">-</span> <span class="p">(</span><span class="n">BOOL</span><span class="p">)</span><span class="nf">deleteFeature</span><span class="p">:(</span><span class="n"><a href="../Classes/EsFeature.html">EsFeature</a></span> <span class="o">*</span><span class="p">)</span><span class="nv">feature</span><span class="p">;</span></code></pre>

                        </div>
                      </div>
                      <div>
                        <h4>Parameters</h4>
                        <table class="graybox">
                          <tbody>
                            <tr>
                              <td>
                                <code>
                                <em>feature</em>
                                </code>
                              </td>
                              <td>
                                <div>
                                  <p>人脸特征数据</p>
                                </div>
                              </td>
                            </tr>
                          </tbody>
                        </table>
                      </div>
                      <div>
                        <h4>Return Value</h4>
                        <p>YES: 执行成功，NO：执行失败</p>
                      </div>
                    </section>
                  </div>
                </li>
                <li class="item">
                  <div>
                    <code>
                    <a name="/c:objc(cs)EsFaceIDDbManager(im)updateFeature:"></a>
                    <a name="//apple_ref/objc/Method/-updateFeature:" class="dashAnchor"></a>
                    <a class="token" href="#/c:objc(cs)EsFaceIDDbManager(im)updateFeature:">-updateFeature:<wbr></a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>更新人脸数据</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Objective-C</p>
                          <pre class="highlight objective_c"><code><span class="k">-</span> <span class="p">(</span><span class="n">BOOL</span><span class="p">)</span><span class="nf">updateFeature</span><span class="p">:(</span><span class="n"><a href="../Classes/EsFeature.html">EsFeature</a></span> <span class="o">*</span><span class="p">)</span><span class="nv">feature</span><span class="p">;</span></code></pre>

                        </div>
                      </div>
                      <div>
                        <h4>Parameters</h4>
                        <table class="graybox">
                          <tbody>
                            <tr>
                              <td>
                                <code>
                                <em>feature</em>
                                </code>
                              </td>
                              <td>
                                <div>
                                  <p>人脸特征数据</p>
                                </div>
                              </td>
                            </tr>
                          </tbody>
                        </table>
                      </div>
                      <div>
                        <h4>Return Value</h4>
                        <p>YES: 执行成功，NO：执行失败</p>
                      </div>
                    </section>
                  </div>
                </li>
                <li class="item">
                  <div>
                    <code>
                    <a name="/c:objc(cs)EsFaceIDDbManager(im)deleteByDbName:"></a>
                    <a name="//apple_ref/objc/Method/-deleteByDbName:" class="dashAnchor"></a>
                    <a class="token" href="#/c:objc(cs)EsFaceIDDbManager(im)deleteByDbName:">-deleteByDbName:<wbr></a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>删除数据库</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Objective-C</p>
                          <pre class="highlight objective_c"><code><span class="k">-</span> <span class="p">(</span><span class="n">BOOL</span><span class="p">)</span><span class="nf">deleteByDbName</span><span class="p">:(</span><span class="n">NSString</span> <span class="o">*</span><span class="p">)</span><span class="nv">DbName</span><span class="p">;</span></code></pre>

                        </div>
                      </div>
                      <div>
                        <h4>Parameters</h4>
                        <table class="graybox">
                          <tbody>
                            <tr>
                              <td>
                                <code>
                                <em>DbName</em>
                                </code>
                              </td>
                              <td>
                                <div>
                                  <p>数据库名称</p>
                                </div>
                              </td>
                            </tr>
                          </tbody>
                        </table>
                      </div>
                      <div>
                        <h4>Return Value</h4>
                        <p>YES: 执行成功，NO：执行失败</p>
                      </div>
                    </section>
                  </div>
                </li>
                <li class="item">
                  <div>
                    <code>
                    <a name="/c:objc(cs)EsFaceIDDbManager(im)listPersonIdByDbName:limit:"></a>
                    <a name="//apple_ref/objc/Method/-listPersonIdByDbName:limit:" class="dashAnchor"></a>
                    <a class="token" href="#/c:objc(cs)EsFaceIDDbManager(im)listPersonIdByDbName:limit:">-listPersonIdByDbName:<wbr>limit:<wbr></a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>查询数据库中前limit条数据</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Objective-C</p>
                          <pre class="highlight objective_c"><code><span class="k">-</span> <span class="p">(</span><span class="n">NSArray</span><span class="o">&lt;</span><span class="n">NSString</span> <span class="o">*&gt;</span> <span class="o">*</span><span class="p">)</span><span class="nf">listPersonIdByDbName</span><span class="p">:(</span><span class="n">NSString</span> <span class="o">*</span><span class="p">)</span><span class="nv">dbName</span>
                                        <span class="nf">limit</span><span class="p">:(</span><span class="n">NSString</span> <span class="o">*</span><span class="p">)</span><span class="nv">limit</span><span class="p">;</span></code></pre>

                        </div>
                      </div>
                      <div>
                        <h4>Parameters</h4>
                        <table class="graybox">
                          <tbody>
                            <tr>
                              <td>
                                <code>
                                <em>dbName</em>
                                </code>
                              </td>
                              <td>
                                <div>
                                  <p>数据库名称</p>
                                </div>
                              </td>
                            </tr>
                            <tr>
                              <td>
                                <code>
                                <em>limit</em>
                                </code>
                              </td>
                              <td>
                                <div>
                                  <p>一次最大返回数据个数</p>
                                </div>
                              </td>
                            </tr>
                          </tbody>
                        </table>
                      </div>
                      <div>
                        <h4>Return Value</h4>
                        <p>离线人脸数据</p>
                      </div>
                    </section>
                  </div>
                </li>
                <li class="item">
                  <div>
                    <code>
                    <a name="/c:objc(cs)EsFaceIDDbManager(im)listDbName"></a>
                    <a name="//apple_ref/objc/Method/-listDbName" class="dashAnchor"></a>
                    <a class="token" href="#/c:objc(cs)EsFaceIDDbManager(im)listDbName">-listDbName</a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>获取所有数据库名称</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Objective-C</p>
                          <pre class="highlight objective_c"><code><span class="k">-</span> <span class="p">(</span><span class="n">NSArray</span><span class="o">&lt;</span><span class="n">NSString</span> <span class="o">*&gt;</span> <span class="o">*</span><span class="p">)</span><span class="n">listDbName</span><span class="p">;</span></code></pre>

                        </div>
                      </div>
                      <div>
                        <h4>Return Value</h4>
                        <p>数据库名称数组</p>
                      </div>
                    </section>
                  </div>
                </li>
              </ul>
            </div>
          </section>
        </section>
        <section id="footer">
          <p>&copy; 2022 <a class="link" href="http://www.esandinfo.com" target="_blank" rel="external">Reid.Lee</a>. All rights reserved. (Last updated: 2022-06-09)</p>
          <p>Generated by <a class="link" href="https://github.com/realm/jazzy" target="_blank" rel="external">jazzy ♪♫ v0.13.5</a>, a <a class="link" href="https://realm.io" target="_blank" rel="external">Realm</a> project.</p>
        </section>
      </article>
    </div>
  </body>
</div>
</html>
